﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class aspx_admin_communication_view : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void rpt留言板_ItemCommand(object source, RepeaterCommandEventArgs e)
    {
        if (e.CommandName=="Delete")
        {
            Label lbl = e.Item.FindControl("留言IDLabel") as Label;
            int id = int.Parse(lbl.Text);
            using (ds_名师讲堂TableAdapters.tb_交流互动TableAdapter da = new ds_名师讲堂TableAdapters.tb_交流互动TableAdapter())
            {
                da.Delete(id);
            }
            this.rpt留言板.DataBind();
        }
    }
}